package com.dhj.yygh.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dhj.yygh.model.order.OrderInfo;
import com.dhj.yygh.vo.order.OrderCountQueryVo;
import com.dhj.yygh.vo.order.OrderCountVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface OrderInfoMapper extends BaseMapper<OrderInfo> {
    /**
     * 根据 orderId 查询 OrderInfo 信息
     *
     * @param orderId
     * @return
     */
    OrderInfo getOrderInfoById(@Param("orderId") Long orderId);

    /**
     * 查询 OrderInfo 的统计信息
     *
     * @param orderCountQueryVo
     * @return
     */
    List<OrderCountVo> selectOrderCount(@Param("vo") OrderCountQueryVo orderCountQueryVo);
}